package DAO;

import java.sql.SQLException;
import java.util.List;

import pageUtil.PageB;

public interface BaseDAO<T> {

    public boolean add(T t, String sql) throws Exception;

    public boolean delete(T t) throws Exception;

    public boolean update(T t, String sql) throws Exception;

    public List<T> findAll(int currentPage, int pageSize, String sql) throws Exception;

    public List<T> findAll(String sql) throws Exception;

    public T findById(String id) throws Exception;

    public T findByPropert(T t) throws Exception;

    public int dataCount(String sql)throws Exception;

    public  List<T> findByPage(PageB<T> bean, String sql) throws SQLException;
}
